<template>
  <div class="accountInfo">
    <div class="header">
         <router-link to="/home/home_myInfo" class = "backspace iconfont icon-leftArr"></router-link>账户信息
    </div>
    <div class="userHeader">
      <label>头像</label>
      <div>
        <div class="headerImg"></div>
        <span class = 'iconArrow iconfont icon-rightArr'>
        </span>
      </div>


      <input type="file" name="" id="" value="kong">

    </div>
    <div class="uname">
      <label>用户名</label>
      <span>{{uname}}
        <span class = 'iconArrow iconfont icon-rightArr'>
        </span>
      </span>
    </div>
    <h2>账号绑定</h2>
    <div class="tel">
      <label>手机</label>
      <span>159****9329
         <span class = 'iconArrow iconfont icon-rightArr'>
        </span>
      </span>
    </div>
    <h2>安全设置</h2>
    <div class="pwd">
      <label>登录密码</label>
      <span>
        <span class = 'text'>未设置</span>
         <span class = 'iconArrow iconfont icon-rightArr'>
        </span>
      </span>
    </div>
    <button class = "signOut" @click = "logout">退出登录</button>
  </div>
</template>
<script>
    import "../../static/css/accountInfo.css"
    import "../../static/css/reset.css"
    import "../../static/lib/font/iconfont.css"
    export default {
        data(){
          return {
            uname:"",
          }
        },
        mounted(){
            this.uname = localStorage.getItem('uname');
        },
        methods:{
          logout(){
            var localStorage = window.localStorage;
            localStorage.setItem("uname","");
            this.$router.push('/login');
          }
        }
    }
</script>
<style lang="scss">
    // @import url(../../static/lib/font/iconfont.css)

</style>
